﻿<%@ Page Language="C#" AutoEventWireup="true" enableEventValidation="false" CodeBehind="scheduler_agent_list.aspx.cs" Inherits="Ccit.OA.Scheduler.scheduler_agent_list" %>
<%@ Register assembly="DevExpress.Web.ASPxGridView.v8.1" namespace="DevExpress.Web.ASPxGridView" tagprefix="dxwgv" %>
<%@ Register assembly="DevExpress.Web.ASPxEditors.v8.1" namespace="DevExpress.Web.ASPxEditors" tagprefix="dxe" %>
<%@ Register TagPrefix="ccit" Namespace="Ccit.ServerControls" Assembly="Ccit.ServerControls.ActionForm" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>日程管理-代理设置</title>
       <script language="javascript" type="text/javascript" src="../script/jquery.js"></script>
    <script language="javascript" type="text/javascript" src="../script/StringClass_Ext.js"></script>
    <script language="javascript" type="text/javascript" src="../script/jsonlib.js"></script>
    <script language="javascript" src="../script/jwindow.js" type="text/javascript"></script>
    <script language="javascript" src="../script/jcontrol.js" type="text/javascript"></script>
    <script language="javascript" src="../script/jbase64.js" type="text/javascript"></script>
    <script type="text/javascript">
        function doAdd()
        {
             var strUrl = "scheduler_agent_edit.aspx";
             window.location.href=strUrl;
        }
        function doDel(vuserId,vproxyId)
        {
             if(confirm("是否确定要删除当前选定的信息?")) 
             {
                var MsSchProxy = {};
                MsSchProxy.UserId =vuserId;
                MsSchProxy.ProxyId =vproxyId;
                  var jsonExpr = JSON.stringify(MsSchProxy,function(key,value){return value;});   
                  MsSchProxy = null; 
                  PageMethods.DoOperate(jsonExpr,ClientCallBack);  
             }
        }
       function ClientCallBack(vResult)
       {
            if(vResult!="-999")
            {
                alert("操作成功!");
                 __doPostBack("lnbQuery","");
            }
            else
            {
                alert("服务器忙,请稍候再试!");
            }
       }
    </script>    
</head>
<body>
    <ccit:ActionForm id="form1" runat="server">
    <asp:LinkButton ID="lnbQuery" CssClass="linktext" runat="server" 
                                onclick="lnbQuery_Click"  Visible="false">
                                </asp:LinkButton>
     <asp:ScriptManager ID="ScriptManager1" runat="server" EnablePageMethods="true">
    </asp:ScriptManager>
    <table class="tbToolbar" cellpadding="0" cellspacing="0" width="98%" align="center">
                    <tr>
                        <td align="left">
                            <div class="tbSeparator"></div>
                        </td>
                        <td width="100%" class="titlebar">  
                            日程管理-代理设置
                        </td>                
                        <td align="right">
                            <nobr> 
                                <a  id="lnbAdd" Runat="server" class="linktext"  
                                href="javascript:doAdd()">
							        <img src="../images/toolbar/new.gif" border="0">新增
						        </a> 
                             </nobr>
                        </td> 
                    </tr>
       </table>
       <table cellpadding="0" cellspacing="0" width="98%" align="center">                 
                                <tr>
                                    <td colspan="3" width="100%">
                                      <dxwgv:ASPxGridView ID="dgMain" runat="server" 
                                AutoGenerateColumns="False" Width="100%" KeyFieldName="userId" onhtmlrowcreated="dgMain_HtmlRowCreated" 
                                             >                                                                   
                                            <SettingsPager AlwaysShowPager="True" PageSize="15">
                                                <FirstPageButton Visible="True">
                                                </FirstPageButton>
                                                <LastPageButton Visible="True">
                                                </LastPageButton>
                                            </SettingsPager>
                                             <Styles>
                                                <Row CssClass=""></Row>
                                                <AlternatingRow  CssClass="" Enabled="true"/>
                                                <SelectedRow  CssClass=""></SelectedRow>                
                                            </Styles>  
                                            <Columns> 
                                                <dxwgv:GridViewDataTextColumn    Caption="被代理人" VisibleIndex="1" width="3%"   FieldName="userName">
                                                 <HeaderStyle HorizontalAlign="Center" />
                                                 <CellStyle HorizontalAlign="Center"></CellStyle> 
                                                 
                                                </dxwgv:GridViewDataTextColumn>
                                                <dxwgv:GridViewDataTextColumn Caption="被代理人部门" VisibleIndex="2" width="8%" FieldName="userDept">
                                                  <HeaderStyle HorizontalAlign="Center" />
                                                  <CellStyle HorizontalAlign="Center"></CellStyle>
                                                </dxwgv:GridViewDataTextColumn>
                                                 <dxwgv:GridViewDataTextColumn Caption="被代理人职位" VisibleIndex="3" width="8%" FieldName="userPost">
                                                  <HeaderStyle HorizontalAlign="Center" />
                                                  <CellStyle HorizontalAlign="Center"></CellStyle>
                                                </dxwgv:GridViewDataTextColumn>  
                                                 <dxwgv:GridViewDataTextColumn Caption="代理人" VisibleIndex="4" width="8%" FieldName="proxyName">
                                                  <HeaderStyle HorizontalAlign="Center" />
                                                  <CellStyle HorizontalAlign="Center"></CellStyle>
                                                </dxwgv:GridViewDataTextColumn>
                                                 <dxwgv:GridViewDataTextColumn Caption="代理人部门" VisibleIndex="5" width="8%" FieldName="proxyDept">
                                                  <HeaderStyle HorizontalAlign="Center" />
                                                  <CellStyle HorizontalAlign="Center"></CellStyle>
                                                </dxwgv:GridViewDataTextColumn>
                                                 <dxwgv:GridViewDataTextColumn Caption="代理人职位" VisibleIndex="6" width="8%" FieldName="proxyPost">
                                                  <HeaderStyle HorizontalAlign="Center" />
                                                  <CellStyle HorizontalAlign="Center"></CellStyle>
                                                </dxwgv:GridViewDataTextColumn>
                                                 <dxwgv:GridViewDataTextColumn Caption="被代理人可修改日程" VisibleIndex="7" width="8%" FieldName="modifyFlag">
                                                  <HeaderStyle HorizontalAlign="Center" />
                                                  <CellStyle HorizontalAlign="Center"></CellStyle> 
                                                  </dxwgv:GridViewDataTextColumn>
                                                 <dxwgv:GridViewDataTextColumn  VisibleIndex="6"  Visible="false" FieldName="proxyId">                                                 
                                                </dxwgv:GridViewDataTextColumn>
                                                 <dxwgv:GridViewDataTextColumn Caption="操作" VisibleIndex="9" width="6%">
                                                  <HeaderStyle HorizontalAlign="Center" />
                                                  <CellStyle HorizontalAlign="Center"></CellStyle>
                                                   <DataItemTemplate>
                                                   <nobr> 
                                                        <a id="lnbDel" runat="server">删除</a>   
                                                   </nobr>
                                                   </DataItemTemplate>
                                                </dxwgv:GridViewDataTextColumn>
                                            </Columns> 
                                        </dxwgv:ASPxGridView>
                                    </td>
                                </tr>
                            </table>
    </ccit:ActionForm>
</body>
</html>
